﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="EyeOpen.Cart.Web._Default" Theme="Base" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="mainForm" runat="server">
    <div>
        <asp:ScriptManager runat="server" />
        <div id="customers" class="datasheet excel2007">
            <div class="outer">
                <div class="inner">
                    <asp:UpdatePanel ID="articleLineListUpdatePanel" runat="server">
                        <ContentTemplate>
                            <asp:ObjectDataSource id="articleLineListObjectDataSource" runat="server" 
                                SelectMethod="GetAll"
                                TypeName="EyeOpen.Cart.Web.Service.ArticleLineClient" 
                            />
                            <asp:ListView ID="articleLineListListView" runat="server" 
                                DataSourceID="articleLineListObjectDataSource"
                                DataKeyNames="Id" 
                                ondatabound="ArticleLineListListView_DataBound">
                                <LayoutTemplate>
                                    <table class="datatable" cellpadding="0" cellspacing="0">
                                        <tr>
                                            <th class="first">Id</th>
                                            <th style="width: 100px">Product name</th>  
                                            <th>Price</th>
                                            <th>Quantity</th>
                                            <th>IVA</th>
                                            <th class="last">Total</th>
                                        </tr>
                                        <tr id="itemPlaceholder" runat="server" />
                                    </table>
                                </LayoutTemplate>
                                <ItemTemplate>
                                    <tr>
                                        <th class="first">
                                            <asp:Label ID="idLabel" runat="server"
                                                Text='<%# Bind("Id") %>' />
                                        </th>
                                        <td>
                                            <asp:Label id="productNameLabel" type="text" runat="server" 
                                                Text='<%# Bind("ProductName") %>' />
                                        </td>
                                        <td>
                                            <asp:TextBox id="priceTextBox" type="text" runat="server" 
                                                Text='<%# Bind("Price") %>' AutoPostBack="true" OnTextChanged="OnArticleLineChanged" />
                                        </td>
                                        <td>
                                            <asp:TextBox ID="quantityTextBox" runat="server" 
                                                Text='<%# Bind("Quantity") %>' AutoPostBack="true" OnTextChanged="OnArticleLineChanged" />
                                        </td>
                                        <td>
                                            <asp:TextBox ID="ivaTextBox" runat="server" 
                                                Text='<%# Bind("Iva") %>' AutoPostBack="true" OnTextChanged="OnArticleLineChanged" />
                                        </td>
                                        <th class="last">
                                            <asp:Label ID="totalLabel" runat="server" 
                                                Text='<%# Bind("Total") %>' />
                                        </th>
                                    </tr>
                                </ItemTemplate>
                            </asp:ListView>
                            <table class="datatable" cellpadding="0" cellspacing="0">
                                <tr>
                                    <td style="text-align: right"><asp:Label id="articleTotal" runat="server" Text="0" /></td>
                                </tr>
                            </table>
                            </div> 
                            </div>
                        </ContentTemplate>
                    </asp:UpdatePanel>
                </div>
            </div>
        </div>
    </div>
    </form>
</body>
</html>